import constConfig from '../constant'
import { ReactVideo, useSetErrorCode } from '../react-video'
import omit from 'lodash-es/omit'

const Index = props => {
  const hlsConfig = constConfig.hlsConfig

  return (
    <div style={constConfig.style}>
      <ReactVideo
        {...omit(props, ['style'])}
        playType="MP4"
        style={constConfig.style}
        hlsConfig={hlsConfig}
        hideNext
        hideJuji
      />
    </div>
  )
}
Index.useSetErrorCode = useSetErrorCode

export default Index
